<?php

namespace app\models;

use Yii;
use yii\base\Model;

/**
 * ContactForm is the model behind the contact form.
 */
class CanloginForm extends Model
{
    public $name;
    public $can_login;

    /**
     * @return array the validation rules.
     */
    public function rules()
    {
        return [
            [['name', 'can_login'], 'required'],
            ['can_login','in', 'range' => [0,1]],
        ];
    }

    /**
     * @return array customized attribute labels
     */
     public function attributeLabels()
     {
         return [
             'name' => '会员名',
             'can_login' => '允许登录'
         ];
     }

}
